﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Text;

namespace YYTea.Services.VModel
{
    public class UserRegister
    {
        [Required]
        [EmailAddress(ErrorMessage = "请输入正确的邮箱地址")]
        /// <summary>
        /// 登录名x
        /// </summary>
        public string UserName { get; set; }
        [Required] 
        [StringLength(100, ErrorMessage = "错误", MinimumLength = 1)]
        /// <summary>
        /// 密码
        /// </summary>
        public string Password { get; set; }
        [Required]
        [Compare(nameof(Password), ErrorMessage = "密码不一致")]
        public string ConfirmPassord { get; set; }
        [Phone(ErrorMessage ="请输入正确的电话号码")]
        public string PhoneNumber { get; set; }

    }
}
